package com.zzq.my.jetpacks.jectpackapp.adapter

import com.chad.library.adapter.base.BaseSectionQuickAdapter
import com.chad.library.adapter.base.viewholder.BaseViewHolder
import com.zzq.my.jetpacks.jectpackapp.R
import com.zzq.my.jetpacks.jectpackapp.bean.AccountInRecordInfo2

/**
 * 描述：class describe
 * 作者：zhuangzeqin
 * 时间: 2022/9/11-21:47
 * 邮箱：zzq@eeepay.cn
 * 备注:
 */
class AccountInRecordGroupAdapter2(data:MutableList<AccountInRecordInfo2>):BaseSectionQuickAdapter<AccountInRecordInfo2,BaseViewHolder>(R.layout.shop_incoming_item_record_in_head,R.layout.shop_incoming_item_record_in_content,data) {
    override fun convert(holder: BaseViewHolder, item: AccountInRecordInfo2) {
        holder.setText(R.id.tv_title, item.childItem?.itemTitle)
        holder.setText(R.id.tv_sub_date, item.childItem?.itemDate)
        holder.setText(R.id.atv_amount, item.childItem?.itemAmount)
    }

    override fun convertHeader(holder: BaseViewHolder, item: AccountInRecordInfo2) {
        holder.setText(R.id.tv_date, item.date)
        holder.setText(R.id.tv_total, item.total)
        holder.setText(R.id.tv_num, item.count)
    }
}